package com.fulu.game.bi.mysql.bi.channel;

import com.fulu.game.bi.entity.po.channel.RegistSourceGroup;
import com.fulu.game.bi.entity.vo.channel.source.RegisterSourceGroupQueryVO;
import com.fulu.game.bi.mysql.bi.ICommonDao;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface RegisterSourceGroupDao extends ICommonDao<RegistSourceGroup, Integer> {

    /**
     * 列表查询
     */
    List<RegistSourceGroup> list(RegisterSourceGroupQueryVO vo);

    /**
     * 列表查询
     */
    List<Integer> listItem(@Param("groupId") Integer groupId);

    /**
     * 修改非空值
     */
    int updateSelective(RegistSourceGroup group);

    /**
     * 插入新记录
     */
    int insert(RegistSourceGroup group);

    /**
     * 通过ID获取name
     */
    String findNameById(@Param("registerSourceGroupId") Integer registerSourceGroupId);

    /**
     * 通过ID获取name
     */
    List<String> findNameByIds(@Param("ids") List<Integer> ids);

    /**
     * 根据name查询
     */
    RegistSourceGroup findByName(@Param("groupName") String groupName);

    int deleteById(@Param("id") Integer id);


}
